package com.ltmonitor.service.impl;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.ltmonitor.dao.IVideoMp4KeyFrameDao;
import com.ltmonitor.video.entity.VideoMp4KeyFrame;
import com.ltmonitor.service.IVideoMp4KeyFrameService;

@Service("videoMp4KeyFrameService")
public class VideoMp4KeyFrameService extends BaseService<Long, VideoMp4KeyFrame> implements IVideoMp4KeyFrameService {

	@Autowired
	private IVideoMp4KeyFrameDao VideoMp4KeyFrameDao;


	public VideoMp4KeyFrame getVideoMp4KeyFrameByFileName(String filePath)
	{
		String filePath1 = filePath.replace('/', '\\');
		String hql = "from VideoMp4KeyFrame where (mp4FilePath = ? or mp4FilePath = ? )and keyFrames is not null";
		return this.VideoMp4KeyFrameDao.find(hql, new Object[]{filePath, filePath1});
	}


}
